
/**************************************************************************************************************************

配置说明

1. 通过 vf.add() 方法增加配置规则,可按模块划分到不同的配置文件。

2. 规则格式为

	{
		"form":
		[
			["ele",		"vele",		"rule",		"msg",		"event",	"nocache"],		//ele
			["ele2",	"vele",		"rule",		"msg",		"event",	"nocache"],		//ele2
			["ele3",	"vele",		"rule",		"msg",		"event",	"nocache"]		//ele3
		],

	}

	form: 表单的标识,可以是name,id,class

	ele:	验证元素的标识
	vele:	验证信息的显示元素标识,可为空,默认为"idVmsg",如果"idVmsg"不存在,则系统自动添加
	rule:	验证规则,同原来一样
	msg:	验证失败提示信息
	event:	[可选] 指定验证触发的事件,默认为"blur,change", 可选"keyup,keydown,click......"
	nocache:[可选] 指定验证缓存项,0代表缓存1为不缓存,默认为0
	

3. 规则的继承,避免类似表单的重复定义


	{
		"form":
		[
			["ele",		"vele",		"rule",		"msg",		"event",	"nocache"],		//ele
			["ele2",	"vele",		"rule",		"msg",		"event",	"nocache"],		//ele2
			["ele3",	"vele",		"rule",		"msg",		"event",	"nocache"]		//ele3
		],

		"form2:form":
		[
			["ele"],	//移除ele规则
			["ele2",	"vele",		"rule",		"msg",		"event",	"nocache"],		//重写ele2规则
			["ele4",	"vele",		"rule",		"msg",		"event",	"nocache"]		//新增ele4规则
		]
	}

	以上为两个表单的验证配置,form和form2

	form2继承了form的配置,写法为 form2:form, 可继承多个表单配置: form2:a,b,c


**************************************************************************************************************************/







vf.add({
		
		"file":		//可能不会有file这个表单,仅作"抽象类"使用
		[
			["#file","","(bt)(ext[jpg,png,gif])","(必填)(格式错误)"]	
		],
	
	
		"customer:file":	//用户继承file
		[	
			["#email","","(bt)(email)(unique[/bltuan/user/customer/try/checkEmail,email,Y])","(必填)(格式不正确)(邮箱已经存在)"],
			["#username","","(bt)(len[6,10])","(必填)(6-10个字符)"],
			["#password","","(bt)(len[6,10])","(必填)(6-10个字符)"],
			["#passwordAgain","","(bt)(equal[password])","(两次密码不一样)"]
		],
	
		"login":	//用户注册
			[	
				["#email","","(bt)(email)","(必填)(格式不正确)"],
				["#password","","(bt)(len[6,10])","(必填)(6-10个字符)"],
			],

		"setting":	//用户注册
			[	
			 	["#username","","(bt)(len[4,15])(unique[/bltuan/user/customer/try/checkUsername,username,Y])","(必填)(4-15个字符)(用户已经存在)"],
			 	//["#username","","(bt)(len[4,15])","(必填)(4-15个字符)"],
				["#password","","(!bt|len[6,10])","(6-10个字符)"],
				["#passwordAgain","","(equal[password])","(两次密码不一样)"],
				["#phone","","(bt)(phone)","(必填)(格式不正确)"]
			],
			
		"businesser":	//商家登记
			[	
				["#call","","(bt)(len[6,10])","(必填)(6-10个字符)"],
				["#phone","","(bt)(phone)","(必填)(格式不正确)"],
				["#contact","","(bt)(len[1,85])","(必填)(1-85个字符)"],
				["#name","","(bt)(len[6,10])","(必填)(6-10个字符)"],
				["#content","","(bt)((len[1,200])","(必填)(1-200个字符)"]
			],
			
		"unit:customer":	//单位注册继承user
		[
			["#unitName",		"",			"bt",		"必填"],
			["#address",		"",			"bt",		"必填"]
		]
	
	});


